/*
 * High Performance Time
 */

#ifndef HPTIME_H_INCLUDED
#define HPTIME_H_INCLUDED

#include <stdint.h>

#include "reporting.h"

#define HPTIME_ERRCODE_BASE           (4900)
#define HPTIME_ERR_FOPEN_FAILED       (HPTIME_ERRCODE_BASE + 1)


typedef uint64_t usec_t;

#define HPTIME_SYNC_INTERVAL	(1000000)

#ifdef HPTIME_INLINE_ALL
#define HPTIME_STATIC static
#include "hptime.c"
#else
#define HPTIME_STATIC
int hptime_init(void);
usec_t hptime_get_time(void);
#endif

#endif /* HPTIME_H_INCLUDED */
